package com.xer.dataload;

import com.ibm.ws.webservices.xml.wassysapp.systemApp;

public class CustomGenerateProductDataload {

	
	public static void main(String[] args) {
		String[] categorias = 
		{
				"elAcessorioselAcessorios"
		};
		String[] productos = 
		{
				"elAcessorioselAcessorios"
		};
		int i= 0;
		System.out.println("CatalogEntry,,,,,,,,,,,,,");
		System.out.println("PartNumber,Type,ParentPartNumber,Sequence,ParentGroupIdentifier,CurrencyCode,ListPrice,Price,Name,ShortDescription,LongDescription,Thumbnail,FullImage,Delete");
		
		for (String categoria : categorias) {
			//part number
			String productPartNumber = "TPRD0000"+i;
			String itemPartNumber = "TITM0000"+i;
			//name
			String productName = "productTEST0000"+i;
			String itemName = "itemTEST0000"+i;
			//short description
			String productShortDesc=productName+" SHORT DESC";
			String itemShortDesc=itemName+" SHORT DESC";
			//long description
			String productLongDesc=productName+" LONG DESC";
			String itemLongDesc=itemName+" LONG DESC";
			
			//CSV PRODUCTO 
			//productPartNumber,categoria,productName,productShortDesc,productLongDesc
			String producto ="%s,Product,,1,%s,BRL,30,25,%s,%s,%s,images/catalog/mens_pants_cords_sm.gif,images/catalog/mens_pants_cords.gif,0";
			String paramsProd[] ={productPartNumber,categoria,productName,productShortDesc,productLongDesc};
			//CSV ITEM 
			//itemPartNumber,productPartNumber,categoria,itemName,itemShortDesc,itemLongDesc
			String item = "%s,Item,%s,1,%s,BRL,30,25,%s,%s,%s,,,0";
			String paramsItem[] ={itemPartNumber,productPartNumber,categoria,itemName,itemShortDesc,itemLongDesc};
			//ProductBean
			System.out.println(String.format(producto, (Object[])paramsProd));
			//ItemBean
			System.out.println(String.format(item, (Object[])paramsItem));
			
			
			
			
			i++;
		}
	}

}
